package com.htwy.core.model;

import com.htwy.ext.BaseMappingKit;
import com.jfinal.plugin.activerecord.ActiveRecordPlugin;

public class MappingKit extends BaseMappingKit {
    @Override
    public void mapping(ActiveRecordPlugin arp) {
        addSqlTemplate(arp, "com.htwy.core.sql", "com.htwy.core.model.Account.sql.tpl", "com.htwy.core.model.Dataset.sql.tpl", "com.htwy.core.model.Dictionary.sql.tpl", "com.htwy.core.model.Menu.sql.tpl", "com.htwy.core.model.Orgnazation.sql.tpl", "com.htwy.core.model.Permission.sql.tpl", "com.htwy.core.model.Role.sql.tpl", "com.htwy.core.model.Attachment.sql.tpl");

        addMapping(arp, "ht_sys_orgnazation", "uuid", Orgnazation.class);
        addMapping(arp, "ht_sys_dictionary", "uuid", Dictionary.class);
        addMapping(arp, "ht_sys_dataset", "uuid", Dataset.class);
        addMapping(arp, "ht_sys_role", "uuid", Role.class);
        addMapping(arp, "ht_sys_account", "uuid", Account.class);
        addMapping(arp, "ht_sys_permission", "uuid", Permission.class);
        addMapping(arp, "ht_sys_menu", "uuid", Menu.class);
        addMapping(arp, "ht_sys_attachment", "uuid", Attachment.class);
    }
}
